package com.qf.controller;

import com.qf.service.UploadService;
import com.qf.utils.ResultMsg;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;

@RestController
@RequestMapping("/upload")
public class UploadController {
    @Autowired
    UploadService uploadService;

    @PostMapping("/pictureUpload")
    public ResultMsg pictureUpload(MultipartFile file) {
        return uploadService.pictureUpload(file);
    }
}
